package com.meixiang.activity.homes.staging;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.meixiang.R;
import com.meixiang.main.BaseActivity;
import com.meixiang.view.ColorArcProgressBar;
import com.meixiang.view.TitleView;

import butterknife.Bind;
import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * @author yinsujun  Created at 2016/5/5 10:24
 */
public class StagingActivity extends BaseActivity {
    @Bind(R.id.title)
    TitleView title;
    @Bind(R.id.staging_tv_promote)
    TextView tvPromote;
    @Bind(R.id.staging_tv_this_month_return)
    TextView tvThisMonthReturn;
    @Bind(R.id.staging_relative_this_month)
    RelativeLayout relativeThisMonth;
    @Bind(R.id.staging_tv_next_month_return)
    TextView tvNextMonthReturn;
    @Bind(R.id.staging_relative_next_month)
    RelativeLayout relativeNextMonth;
    @Bind(R.id.staging_tv_order)
    TextView tvOrder;
    @Bind(R.id.staging_tv_history_check)
    TextView tvHistoryCheck;
    @Bind(R.id.staging_arcProgressBar)
    ColorArcProgressBar arcProgressBar;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        setContentView(R.layout.activity_staging);
        ButterKnife.bind(this);
        super.onCreate(savedInstanceState);
    }

    @Override
    protected void initTitle() {
        setTitleBackground("美分期", R.mipmap.ic_white_back);
        arcProgressBar.setCurrentValues(80);

//        setTitle("美分期", "");
//        title.setBackgroundColor(ContextCompat.getColor(context,R.color.staging_theme_color));


    }

    @Override
    protected void initView() {

    }

    @OnClick({R.id.staging_tv_promote, R.id.staging_relative_this_month, R.id.staging_relative_next_month,R.id.staging_tv_order, R.id.staging_tv_history_check})
    void click(View view) {
        Intent intent = new Intent();
        if (view.equals(tvPromote)) {
            intent.setClass(context, PromoteForBindingActivity.class);
        } else if (view.equals(relativeThisMonth)) {
            intent.setClass(context, CheckDetailsActivity.class);
        } else if(view.equals(relativeNextMonth)){
            intent.setClass(context, CheckDetailsActivity.class);
        }else if (view.equals(tvOrder)) {
            intent.setClass(context, StagingOrderActivity.class);
        } else if (view.equals(tvHistoryCheck)) {
            intent.setClass(context, StagingHistoryCheckActivity.class);
        }
        startActivity(intent);
    }

    @Override
    protected void setData() {

    }

    @Override
    public void onClick(View v) {

    }
}
